/**
 * 中国象棋工具统一导出
 */

// 引擎相关
export { ChessEngine } from './engine/ChessEngine.js';
export { GameState } from './engine/GameState.js';

// AI相关
export { ChessAI, chessAI } from './ai/ChessAI.js';
export { 
  isPathClear,
  countPiecesInPath,
  getPathPositions,
  getManhattanDistance,
  getChebyshevDistance,
  getAdjacentPositions,
  getOrthogonalPositions,
  getDiagonalPositions,
  findFirstPieceInDirection,
  getEmptyPositions,
  getPiecePositions,
  positionsEqual,
  positionToString,
  stringToPosition,
  boardToString,
  cloneBoard
} from './engine/BoardUtils.js';

// 规则相关
export { 
  moveRules,
  isValidPieceMove,
  getPossibleMoves,
  getAllPossibleMoves
} from './rules/moveRules.js';
export { 
  isInCheck,
  findKingPosition,
  wouldBeInCheckAfterMove,
  isValidMove,
  getAllValidMoves,
  isCheckmate,
  isStalemate,
  isDraw,
  makeMove,
  getValidMovesForPiece,
  checkGameEnd
} from './rules/gameRules.js';

// 常量
export { 
  PIECES,
  PIECE_TYPES,
  PIECE_VALUES,
  COLORS,
  INITIAL_BOARD,
  POSITION_VALUES
} from './constants/pieces.js';
export { 
  BOARD_SIZE,
  PALACE_BOUNDS,
  RIVER_BOUNDARY,
  ELEPHANT_BOUNDS,
  DIRECTIONS,
  SPECIAL_POSITIONS,
  isValidPosition,
  isInPalace,
  isInOwnSide,
  isElephantInBounds
} from './constants/positions.js';
export { 
  GAME_STATUS,
  MOVE_RESULT,
  GAME_MODE,
  AI_DIFFICULTY,
  BOARD_CONFIG,
  SOUND_CONFIG,
  TIMER_CONFIG,
  SAVE_CONFIG,
  INPUT_CONFIG,
  DEFAULT_SETTINGS
} from './constants/gameConfig.js';
